@mixin border-1px ($color, $radius: 0px){
  position:relative;
  &::after{
    display:block;
    position:absolute;
    left:0;
    bottom:0;
    width: calc(100% - 1Px * 2);
    height: calc(100% - 1Px * 2);
    content:' ';
    border: 1Px solid $color;
    border-radius: $radius;
  }
}

@mixin border-top-1px ($color){
  position:relative;
  &::after{
    display:block;
    position:absolute;
    left:0;
    bottom:0;
    width:100%;
    height: 1Px;
    background-color: $color;
    content:' ';
    z-index: 1;
  }
}

//媒体查询
@media (min-device-pixel-ratio:1.5){
  .border-1px::after{
    transform:scaleY(0.7) !important;
  }
}

//有多个值，可以根据项目需求定义更多的值来适配不同的机型，详细请查看本文最后的参考
@media (min-device-pixel-ratio:2){
  .border-1px::after{
    transform:scaleY(0.5) !important;
  }
}